﻿
<!DOCTYPE html>
<html lang="zh-cn">
<head>

    <title>新蓝领云招聘 v1.0</title>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit"/>
    <title><?php echo config('system_name'); ?></title>
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <link rel="shortcut icon" href="__STATIC__/img/favicon.ico" />
    <link rel="stylesheet" href="__STATIC__/plugs/awesome/css/font-awesome.min.css?ver={:date('ymd')}">
    <link rel="stylesheet" href="__STATIC__/plugs/bootstrap/css/bootstrap.min.css?ver={:date('ymd')}"/>
    <link rel="stylesheet" href="__STATIC__/plugs/layui/css/layui.css?ver={:date('ymd')}"/>
    <link rel="stylesheet" href="__STATIC__/theme/default/css/console.css?ver={:date('ymd')}">
    <link rel="stylesheet" href="__STATIC__/theme/default/css/animate.css?ver={:date('ymd')}">{block name="style"}{/block}
<!--    <script src="__STATIC__/plugs/require/require.js?ver={:date('ymd')}"></script>-->
<!--    <script src="__STATIC__/admin/app.js?ver={:date('ymd')}"></script>-->
<!--    <script>window.ROOT_URL='__PUBLIC__';</script>-->
    <style>
        body{
            background: url(/static/img/timg.jfif) no-repeat right top;
            background-size: cover;
        }
        .input_title{
            font-size: 14px;
            font-weight: bold;

        }
        .login-container .container{
            height: 685px !important;
        }
        .login-container .login-input{
            border: none !important;
            border-bottom: 1px solid #333 !important;
            background: none !important;
            padding-left: 0px !important;
        }
        .layui-btn{
            background: #D42330 !important;
            border-radius: 200px !important;
        }

        .impowerBox .qrcode {width: 200px;}
        .impowerBox .title {display: none;}
        .impowerBox .info {width: 200px;}
        .status_icon {display: none}

        .account{
            z-index:999999;position:absolute;right:40px !important;margin-top:-50px !important
        }

    </style>
<!--    <script src="/static/js/jquery-1.4.3.min.js"></script>-->
        <script src="/static/js/jquery-3.3.1.min.js"></script>
    <script src="/static/js/layer-3.1.1/layer.js"></script>

</head>
<body>


<link rel="stylesheet" href="__STATIC__/theme/default/css/login.css">

<input type="hidden" name="openid" value="{$openid}">

<div class="login-container full-height">


    <!-- 页面表单主体 开始 -->
    <div class="container">
        <div   class="content layui-form animated fadeInDown"
              style="    background: white;width:20%;
    padding: 20px 40px;
    border-radius: 10px;
    margin-top: 150px;">

            <div style="text-align: left;margin-bottom: 40px;margin-top:40px;text-align:left">
                <span style="font-size:25px;color:#007bff;font-weight: bold">首次扫码</span>
                <h3>请先绑定手机账号</h3>
            </div>

            <div id="login_container" style="display:none;height:300px;">
            </div>


            <ul id="ul">
                <li>
                    <p class="input_title" style="color:#007bff">手机号</p>
                    <input required="required" pattern="^\S{2,}$" value="" name="username"
                           autofocus="autofocus" autocomplete="off" class="login-input "
                           title="请输入2位及以上的字符" placeholder="请输入..."/>
                </li>
                <li>
                    <p class="input_title" style="color:#007bff">密码</p>
                    <input required="required" pattern="^\S{4,}$" value="" name="password"
                           type="password" autocomplete="off" class="login-input "
                           title="请输入4位及以上的字符" placeholder="请输入..."/>
                </li>


                <li class="text-center" style="margin-top:20px;">
                    <button type="button" style="background:#007bff !important;" onclick="submit()" class="layui-btn " >绑 定 账 号</button>
                    <!--<a style="position:absolute;display:block;right:0" href="javascript:void(0)">忘记密码？</a>-->
                </li>
            </ul>
        </div>
    </div>

    <!-- 页面表单主体 结束 -->

    <!-- 底部版权信息 开始 -->
    <div class="footer notselect"><?php echo config('copyright'); ?></div>
    <!-- 底部版本信息 结束 -->

</div>


<script>
  function submit()
  {
      let data = {};
      data.name = $("[name='username']").val();
      data.password = $("[name='password']").val();
      data.openid = $("[name='openid']").val();
      if(data.name.length < 2)
      {
          layer.tips('账号不能少于2位数',$("[name=username]"),{icon:2,position:'top'});return;
      }
      if(data.password.length < 4)
      {
          layer.tips('密码不能少于4位数',$("[name=password]"),{icon:2});return;

      }
      $.ajax({
          type:'post',
          url:'verificationAccount',
          data:{data:data},

      }).then(function(res)
      {
          if(res.code == -1)
          {
              window.layer.msg(res.msg,{icon:2})
          }
          else{
              window.location.href='/admin';
          }
      })
  }

  $("body").on('keydown',function(res)
  {
      if(res.keyCode == 13)
      {
          submit();
      }
  })
</script>


</body>
</html>



